﻿namespace DslEditorPowerToy.Controls
{
    using System;
    using System.Drawing;
    using System.Windows.Forms;

    public class HostedEditor
    {
        private string _caption = string.Empty;
        private System.Windows.Forms.Control _control;
        private Guid _id;
        private Bitmap _image;

        public HostedEditor(Guid id, System.Windows.Forms.Control control, string caption, Bitmap image)
        {
            this._id = id;
            this._control = control;
            this._caption = caption;
            this._image = image;
        }

        public override string ToString()
        {
            if (!string.IsNullOrEmpty(this.Caption))
            {
                return this._caption;
            }
            return base.ToString();
        }

        public string Caption
        {
            get
            {
                return this._caption;
            }
        }

        public System.Windows.Forms.Control Control
        {
            get
            {
                return this._control;
            }
        }

        public Guid Id
        {
            get
            {
                return this._id;
            }
        }

        public Bitmap Image
        {
            get
            {
                return this._image;
            }
        }
    }
}

